package com.neuedu.mobilebank.service.serviceimpl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.neuedu.mobilebank.mapper.TransRecordMapper;
import com.neuedu.mobilebank.po.ResponseBean;
import com.neuedu.mobilebank.po.TransRecordSub;
import com.neuedu.mobilebank.service.TransRecordService;
@Service
public class TransRecordServiceImpl implements TransRecordService {
	
	@Autowired
	private TransRecordMapper trm;
	
	@Override
	public ResponseBean<List<TransRecordSub>> findTransRecord(Integer accountId) {
		// TODO Auto-generated method stub
		List<TransRecordSub> list=trm.findTransRecord(accountId);
		ResponseBean<List<TransRecordSub>> rb=null;
		if(list.size()>0){
			rb=new ResponseBean<>(list);
		}else{
			rb=new ResponseBean<>(801,"没有交易记录数据");
		}
		return rb;
	}

}
